1. Field of the Invention
The present invention relates to a method for replacing defective areas and to an information writing/reading device having the functions for executing replacement, and particularly to a defective area replacement method and information writing/reading device capable of maintaining both the transfer rate and reliability of data.
2. Description of the Related Art
An information writing/reading device of the prior art is first described with reference to the accompanying figures. Recording medium 9 shown in FIG. 1 is, for example, an optical disk medium with tracks that are cut in accordance with spiral or concentric guide grooves, the writing marks of the tracks being formed according to the intensity of a condensed laser beam that is irradiated upon the recording medium by head 8. As shown in FIG. 2, the tracks formed on recording medium 9 are in turn formed from header portions in which physical address data are written at fixed intervals to indicate locations on tracks, and data portions used for writing data. A sector is constituted by an area made up by a header portion paired with a data portion. Physical addresses are assigned without duplication to all sectors on a track.
Sectors on the recording medium are further divided into a plurality of areas by physical addresses.
FIG. 3 is a schematic view showing one example of the format of a recording medium. A lead-in area made up of a plurality of sectors is provided at the start of a track, and a lead-out area made up of a plurality of sectors is also provided at the end of a track. The lead-in area. and lead-out area are not used for writing and reading data, and only physical addresses are written in these areas. Detection of these physical addresses allows determination of whether the relevant area is not to be subject to writing/reading. Defect management areas are provided in two locations: just inside the lead-in area and lead-out areas. A plurality of user areas and spare areas are provided inside these two areas. Spare areas are provided at the end of zones that are partitioned according to, for example, the number of sectors contained in one rotation of the disk, and the proportion of spare areas is approximately 0.5% that of the user areas.
Information relating to defective sectors in the user areas and spare areas is recorded in defect management areas, defect management areas being provided in at least two locations. In this way, despite the occurrence of a defective sector in the sectors of one defect managing area, the other defect management area can provide back-up so that information relating to defective sectors in the user areas and spare areas is not lost. Recording identical information in a plurality of areas allows use of defect management information as long as reading of any set of information is successful.
The information written in a defect management area is made up by a slip replacement list and a linear replacement list. Defective sectors are indicated using the type of format shown in FIG. 4, which shows one example of the write format in a defect management list.
The physical addresses of defective sectors that were extracted in the certification process are written in the slip replacement management list shown in this figure. In order from the beginning, the list includes: a slip replacement list identification number, which indicates that the content of the list is a slip replacement list; the number of slip replacement defects registered in the list; and the physical addresses of defective sectors. A buffer area is provided at the end of the slip replacement list so that the length of the list can be kept uniform regardless of the number of defects registered.
The linear replacement list is written after the slip replacement list. The linear replacement list is used for replacement of sectors having secondary defects not detected during certification. In order from the beginning, the list includes: a linear replacement list identification number indicating that the content of the list is a linear replacement list; the number of list updates; and the number of linear replacement defects registered in the list, following which a number of replacement origin physical addresses, each paired with a replacement destination physical address, are written, the number of these pairs being equal to the number of registered defects. Finally, the number of list updates is again recorded at the end. The linear replacement list portion of the data recorded in the defect management area can be rewritten. The number of updates is recorded in two locations, i.e, close to the beginning and at the end of the linear replacement list, to allow verification that the list has been correctly updated. A discrepancy between these two numbers allows determination of the possibility of an interruption in writing when the list was updated.
Returning now to FIG. 1, the flow of processes in an information writing/reading device is next explained. At the time of starting up information writing/reading device 10, CPU 1 instructs head position control circuit 6 to read the defect management areas of recording medium 9. Head 8 moves to a defect management area under the control of head position control circuit 6 and outputs the read signals. The read signals output from head 8 are sent as data of the defect management area to disk control circuit 4 by way of write/read signal processing circuit 7 and format control circuit 3. Disk control circuit 4 stores the data of the defect management area in buffer memory 5. The data of the defect management area that is temporarily stored in buffer memory 5 is further read from buffer memory 5 by disk control circuit 4 and transferred to the slip replacement list storage section and linear replacement list storage section of memory 2.
The replacement of defective areas in the write/read operations of recording medium 9 is executed based on the information that is in the slip replacement list storage section and linear replacement list storage section in memory 2.
A write request from host device 11 is sent to disk control circuit 4 along with logical addresses indicating the write locations. Disk control circuit 4 reports to CPU 1 that a write request from host device 11 has been generated. CPU 1 receives the content of the request from disk control circuit 4 and instructs disk control circuit 4 to transfer data from host device 11 to buffer memory 5. The data to be written are thus taken from host device 11 by disk control circuit 4 and temporarily stored in buffer memory 5.
In CPU 1, the physical addresses on recording medium 9 are calculated from the logical addresses of the data to be written, and a write request of the data that are to be written to the calculated physical addresses is sent to head position control circuit 6 and format control circuit 3.
FIG. 5 is a block diagram that focuses on, of the functions of CPU 1, memory 2, and format control circuit 3 in information writing/reading device 10, the functions that are related to replacement processing and address conversion processing.
In FIG. 5, address converting means 103 provided in CPU 1 is equipped with functions for calculating the physical addresses of recording medium 9 that correspond to the logical addresses of the data to be written using the information of slip replacement list storage section 202 and linear replacement list storage section 203 that are provided in memory 2.
Head 8 moves in the direction of the physical addresses of recording medium 9 based on the control of head position control circuit 6 and in addition, outputs address signals read from recording medium 9. The address signals are sent to format control circuit 3 by way of write/read signal processing circuit 7. Upon detecting the physical addresses designated by CPU 1, format control circuit 3 receives the data to be written from buffer memory 5 by way of disk control circuit 4, and sends the data to be written to write/read signal processing circuit 7. Write/read signal processing circuit 7 processes the data to be written to data of a waveform suitable for writing and carries out operations for writing the data onto recording medium 9 through head 8.
The details regarding the operation of calculating the physical addresses from logical addresses are next explained.
FIG. 6 is a schematic view showing the assignment of replacement sectors provided for explaining the method of replacing defective areas according to the prior art. FIG. 6 shows a case in which eight sectors are provided for the user areas and four sectors are provided for the spare areas. In actuality, the proportion of spare areas to user areas is on the order of 5%, with 500 sectors of spare areas usually being provided for 100,000 sectors of user areas. If there are no defective sectors, the logical addresses match physical addresses wherein addresses are assigned in an ascending order to the sectors of user areas. The number of slip replacement sectors contained in one user area is established to be equal to or less than the number of spare area sectors that follow that user area. If physical addresses that are registered in the slip replacement list are contained in user areas or in spare areas, the sectors of these addresses are regarded as defective sectors and excluded, and logical addresses are assigned to the remaining physical addresses in ascending order.
If the sectors having physical addresses xe2x80x9c3xe2x80x9d and xe2x80x9c5xe2x80x9d are defective sectors that are registered in the slip replacement list, for example, logical addresses are assigned while avoiding these defective sectors, whereby logical address xe2x80x9c3xe2x80x9d corresponds to physical address xe2x80x9c4xe2x80x9d, and logical addresses xe2x80x9c4xe2x80x9d to xe2x80x9c7xe2x80x9d correspond to physical addresses xe2x80x9c6xe2x80x9d to xe2x80x9c9xe2x80x9d. The sectors having the logical addresses xe2x80x9c8xe2x80x9d and on corresponding to the next user area, however, are not influenced by the number of slip replacement sectors of the preceding user area, and the physical addresses to which logical addresses are assigned are determined by defects in user areas following physical address xe2x80x9c12xe2x80x9d. In other words, the number of slip replacement sectors of a user area is limited by the number of sectors of the spare area.
If defective sectors are registered in the linear replacement list, verification is carried out to determine whether or not physical addresses that were assigned to logical addresses through calculations using the slip replacement list have been registered in the linear replacement list as replacement origin physical addresses. If such an address is registered, the physical address of the replacement origin is replaced by the physical address of the replacement destination. For example, if the physical address xe2x80x9c8xe2x80x9d is registered in the replacement origin sector and physical address xe2x80x9c10xe2x80x9d is registered in the linear alteration destination sector of the linear replacement list, the sector that corresponds to logical address xe2x80x9c6xe2x80x9d is the sector of physical address xe2x80x9c10xe2x80x9d rather than physical address xe2x80x9c8xe2x80x9d that was calculated using the slip replacement list. The sector that corresponds to logical address xe2x80x9c7xe2x80x9d is simply the sector of physical address xe2x80x9c9xe2x80x9d.
When writing digital data to a recording medium, the replacement process is carried out with respect to sectors in which writing abnormalities occur to maintain the reliability of data. Physical address information is written to the recording medium in the case of recording media such as optical disks and magnetic disks. Data cannot be written to a physical address if the physical address of the data to be written cannot be detected, and the physical address is handled as a writing abnormality. Verification in which data are read after writing allows detection of sectors having writing abnormalities in the data portion and further increases reliability.
If a writing abnormality is detected in a sector, this sector is judged to be a defective sector and the replacement process is executed using a spare area that has been provided in advance. Generally, slip replacement is used for primary defects that originate in the fabrication of the disk, and linear replacement is used for secondary defects.
In slip replacement, logical addresses are made to correspond in an ascending order to physical addresses, which are assigned to each sector, while omitting defective sectors. In slip replacement, drops in transfer speed due to the occurrence of seeking can be prevented because the order of logical addresses on the recording medium is maintained. If slip replacement is carried out for secondary defects, however, the assignment of logical addresses to physical addresses will shift at and after addresses at which a substitute sector was added for a defective sector. If there are sectors in which data have already been written and the assignment of logical addresses to these physical addresses changes, the problem arises that the content of these sectors no longer correctly corresponds to the logical addresses. Slip replacement is therefore used only for primary defects that are detected in the certification process.
The occurrence of a secondary defect calls for the use of linear replacement, in which a replacement destination for a defective sector is reserved in a spare area. As shown in FIG. 5, a sector in which a writing abnormality has occurred is detected by abnormality detecting means 301 provided in format control circuit 3. For a sector in which the occurrence of a write abnormality has been detected, replacement destination reserving means 105, which is provided CPU 1, reserves from a free sector in a spare area a replacement destination for the defective sector in which the writing abnormality occurred. Normally, replacement destination sectors are assigned in order starting from sectors of spare areas that are close to the defective sector and that have logical addresses that have not yet been assigned. Linear replacement list updating means 104 provided in CPU 1 additionally registers the physical address of a newly detected defective sector and the physical address of a replacement destination sector to linear replacement list storage section 203 provided in memory 2. Address converting means 103 refers to the information of slip replacement list storage section 202 and the information of linear replacement list storage section 203 that has been updated, assigns a physical address to a logical address, and in this way the writing process is continued to the assigned physical address and linear replacement is realized.
Turning now to the flow chart of FIG. 7, the replacement process of the prior art is described in detail for a case in which a secondary defect occurs.
As shown in FIG. 7, when writing data, the logical address of the data to be written is first acquired from host device 11 (Step B1). The acquired logical address of the data to be written is next converted to a physical address (Step B2). The writing of the data to the obtained physical address is next executed (Step B3), and verification is carried out to determine whether or not writing was carried out normally (Step B4). The occurrence of an abnormality in writing can be recognized if the physical address on the disk could not be verified or if data could not be read from the written area (Step B4 xe2x80x9cNoxe2x80x9d). Here, if writing was carried out normally (Step B4 xe2x80x9cYesxe2x80x9d), host device 11 is notified that writing has been completed (Step B5) and the series of data writing operations ends. On the other hand, if a writing abnormality is recognized in Step B4 (Step B4 xe2x80x9cNoxe2x80x9d), the physical address of the defective sector is added to the linear replacement list as a replacement origin address and a still unused sector is selected from spare areas and registered as the replacement destination address (Step B6). In the interest of shortening the distance of movement of the head, a sector that is close to the physical address of the replacement origin is usually selected as the replacement destination.
However, linear replacement, in which only defective sectors are substituted by replacement destination sectors in spare areas entails a marked increase in processing time over that of slip replacement, in which logical addresses are only shifted back, due to the secondary processing that accompanies head movement.
Replacement for secondary defects is necessary to maintain the quality of write/read data. If secondary defects are ignored, data that are written to these areas are lost.
When using linear replacement, however, it is difficult to always reserve a replacement destination sector at a location that is physically close to the defective sector which is the replacement origin. The frequency of increases in processing time brought about by movement of the head therefore rises, and real-time processing becomes difficult to ensure.
In particular, if the written data are moving image information or speech information in which real time characteristics are demanded, deviation in the timing of writing and reading has the same effect as the occurrence of an error. If replacement of data is not carried out, however, the probability of errors in the read data increases, and reading is adversely affected.
It is an object of the present invention to provide a method, as well as an information writing/reading device, for replacing secondary defect areas that can maintain both the quality and transfer rate of write/read data at high levels.
To solve the problems of the prior art, the method of replacing defective areas according to the present invention uses not linear replacement but slip replacement for processing secondary defects in cases in which the execution of slip replacement has no effect on the assignment of logical addresses outside a change-permitted range. In more concrete terms, a change-premitted range that extends from the sector in which writing or reading instructed by a host device is to be carried out and as far as the next used area is collectively acquired; and when an abnormality is detected in a write destination sector when writing data, if there is a spare area in the change-permitted range following that secondary defect sector, and moreover, if there is a free sector in the spare area, the assignment of sectors is replaced by additionally registering the physical addresses of the secondary defect sectors in the slip replacement list to omit the secondary defect sector and shifting back the assignment of logical addresses in the range that contains free sectors after the secondary defect sector.
The above and other objects, features, and advantages of the present invention will become apparent from the following description based on the accompanying drawings which illustrate an example of a preferred embodiment of the present invention.